\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template}{
\section{com.dstu.autofit.Template Class Reference}
\label{classcom_1_1dstu_1_1autofit_1_1_template}\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}}
}


A small template engine class.  


\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a62922bfac8df52957461007c5f7bc92f}{Template} ()
\begin{DoxyCompactList}\small\item\em Default constructor. \end{DoxyCompactList}\item 
\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a50e8d74ecca3ad50287e5e15757f95f0}{Template} (String textIn)
\begin{DoxyCompactList}\small\item\em This constructor takes the target text as an argument. \end{DoxyCompactList}\item 
void \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_acc464721bfb13b4f0d635a3decce96f4}{setText} (String text)
\begin{DoxyCompactList}\small\item\em Set the target text. \end{DoxyCompactList}\item 
void \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_ae9edf6ace6b278411d470ebd05541189}{set} (String name, Object value)
\begin{DoxyCompactList}\small\item\em Set the property name to value. \end{DoxyCompactList}\item 
void \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_af35288a09eec1a028406b4faabda2bc9}{clear} ()
\begin{DoxyCompactList}\small\item\em Delete all properties and values from values. \end{DoxyCompactList}\item 
String \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a90a98dec8b330c7b8da78d5e22b9d42f}{fillIn} ()
\begin{DoxyCompactList}\small\item\em Fill in the template text with the values supplied. \end{DoxyCompactList}\item 
String \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a5fe9a3d07792eaae69a480003f6b80f5}{fillIn} (boolean check)  throws BlankPropertiesException 
\item 
String \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_ab0ded48407dbbf584a10db70024d24c9}{fillIn} (boolean check, String textIn)  throws BlankPropertiesException 
\begin{DoxyCompactList}\small\item\em Fill in the provided template textIn with the values supplied, checking that all property names in the template have been supplied. If not, throws a \hyperlink{classcom_1_1dstu_1_1autofit_1_1_blank_properties_exception}{BlankPropertiesException}. \end{DoxyCompactList}\item 
String \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_aa95c3c8f422ac0e092a6a0623a5b40ab}{fillIn} (String text)
\begin{DoxyCompactList}\small\item\em Fill in the provided template textIn with the values supplied. \end{DoxyCompactList}\item 
boolean \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a49524b71b2425d4dbcf466d610c4ce8e}{allPropertiesAssigned} ()
\item 
boolean \hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a8882a3ad6313cbc97ce59c19d4e6ee57}{allPropertiesAssigned} (String text)
\begin{DoxyCompactList}\small\item\em Checks that all property names in the template have been supplied to the values member. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
A small template engine class. 

\begin{DoxyAuthor}{Author}
Patrick Niemeyer, Jonathan Knudsen
\end{DoxyAuthor}
This code was copied wholesale by me, Dan Stuart, from O'Reilly's Learning Java, 3rd edition, by Patrick Niemeyer and Jonathan Knudsen, pp 339-\/340. Most of this work is theirs. 

Definition at line 18 of file Template.java.



\subsection{Constructor \& Destructor Documentation}
\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_a62922bfac8df52957461007c5f7bc92f}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!Template@{Template}}
\index{Template@{Template}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{Template}]{\setlength{\rightskip}{0pt plus 5cm}com.dstu.autofit.Template.Template (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_a62922bfac8df52957461007c5f7bc92f}


Default constructor. 

\begin{DoxySeeAlso}{See also}
\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a50e8d74ecca3ad50287e5e15757f95f0}{Template(String textIn)}. 
\end{DoxySeeAlso}


Definition at line 33 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_a50e8d74ecca3ad50287e5e15757f95f0}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!Template@{Template}}
\index{Template@{Template}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{Template}]{\setlength{\rightskip}{0pt plus 5cm}com.dstu.autofit.Template.Template (
\begin{DoxyParamCaption}
\item[{String}]{textIn}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_a50e8d74ecca3ad50287e5e15757f95f0}


This constructor takes the target text as an argument. 

\begin{DoxyAuthor}{Author}
dstu 
\end{DoxyAuthor}


Definition at line 41 of file Template.java.



\subsection{Member Function Documentation}
\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_a49524b71b2425d4dbcf466d610c4ce8e}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!allPropertiesAssigned@{allPropertiesAssigned}}
\index{allPropertiesAssigned@{allPropertiesAssigned}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{allPropertiesAssigned}]{\setlength{\rightskip}{0pt plus 5cm}boolean com.dstu.autofit.Template.allPropertiesAssigned (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_a49524b71b2425d4dbcf466d610c4ce8e}
\begin{DoxyAuthor}{Author}
dstu
\end{DoxyAuthor}
\begin{DoxySeeAlso}{See also}
\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a8882a3ad6313cbc97ce59c19d4e6ee57}{allPropertiesAssigned(String text)} 
\end{DoxySeeAlso}


Definition at line 141 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_a8882a3ad6313cbc97ce59c19d4e6ee57}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!allPropertiesAssigned@{allPropertiesAssigned}}
\index{allPropertiesAssigned@{allPropertiesAssigned}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{allPropertiesAssigned}]{\setlength{\rightskip}{0pt plus 5cm}boolean com.dstu.autofit.Template.allPropertiesAssigned (
\begin{DoxyParamCaption}
\item[{String}]{text}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_a8882a3ad6313cbc97ce59c19d4e6ee57}


Checks that all property names in the template have been supplied to the values member. 

\begin{DoxyAuthor}{Author}
dstu 
\end{DoxyAuthor}


Definition at line 151 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_af35288a09eec1a028406b4faabda2bc9}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!clear@{clear}}
\index{clear@{clear}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{clear}]{\setlength{\rightskip}{0pt plus 5cm}void com.dstu.autofit.Template.clear (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_af35288a09eec1a028406b4faabda2bc9}


Delete all properties and values from values. 

\begin{DoxyAuthor}{Author}
dstu 
\end{DoxyAuthor}


Definition at line 67 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_aa95c3c8f422ac0e092a6a0623a5b40ab}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!fillIn@{fillIn}}
\index{fillIn@{fillIn}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{fillIn}]{\setlength{\rightskip}{0pt plus 5cm}String com.dstu.autofit.Template.fillIn (
\begin{DoxyParamCaption}
\item[{String}]{text}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_aa95c3c8f422ac0e092a6a0623a5b40ab}


Fill in the provided template textIn with the values supplied. 

\begin{DoxyAuthor}{Author}
dstu 
\end{DoxyAuthor}


Definition at line 116 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_a90a98dec8b330c7b8da78d5e22b9d42f}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!fillIn@{fillIn}}
\index{fillIn@{fillIn}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{fillIn}]{\setlength{\rightskip}{0pt plus 5cm}String com.dstu.autofit.Template.fillIn (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_a90a98dec8b330c7b8da78d5e22b9d42f}


Fill in the template text with the values supplied. 

\begin{DoxySeeAlso}{See also}
\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_aa95c3c8f422ac0e092a6a0623a5b40ab}{fillIn(String text)} 
\end{DoxySeeAlso}


Definition at line 76 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_a5fe9a3d07792eaae69a480003f6b80f5}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!fillIn@{fillIn}}
\index{fillIn@{fillIn}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{fillIn}]{\setlength{\rightskip}{0pt plus 5cm}String com.dstu.autofit.Template.fillIn (
\begin{DoxyParamCaption}
\item[{boolean}]{check}
\end{DoxyParamCaption}
)  throws {\bf BlankPropertiesException} }}
\label{classcom_1_1dstu_1_1autofit_1_1_template_a5fe9a3d07792eaae69a480003f6b80f5}
\begin{DoxyAuthor}{Author}
dstu
\end{DoxyAuthor}
\begin{DoxySeeAlso}{See also}
\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a8882a3ad6313cbc97ce59c19d4e6ee57}{allPropertiesAssigned(String text)} 

\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_ab0ded48407dbbf584a10db70024d24c9}{fillIn(boolean check, String textIn)} 

\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_aa95c3c8f422ac0e092a6a0623a5b40ab}{fillIn(String text)} 
\end{DoxySeeAlso}


Definition at line 87 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_ab0ded48407dbbf584a10db70024d24c9}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!fillIn@{fillIn}}
\index{fillIn@{fillIn}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{fillIn}]{\setlength{\rightskip}{0pt plus 5cm}String com.dstu.autofit.Template.fillIn (
\begin{DoxyParamCaption}
\item[{boolean}]{check, }
\item[{String}]{textIn}
\end{DoxyParamCaption}
)  throws {\bf BlankPropertiesException} }}
\label{classcom_1_1dstu_1_1autofit_1_1_template_ab0ded48407dbbf584a10db70024d24c9}


Fill in the provided template textIn with the values supplied, checking that all property names in the template have been supplied. If not, throws a \hyperlink{classcom_1_1dstu_1_1autofit_1_1_blank_properties_exception}{BlankPropertiesException}. 

\begin{DoxyAuthor}{Author}
dstu
\end{DoxyAuthor}
\begin{DoxySeeAlso}{See also}
\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_aa95c3c8f422ac0e092a6a0623a5b40ab}{fillIn(String text)} 

\hyperlink{classcom_1_1dstu_1_1autofit_1_1_template_a8882a3ad6313cbc97ce59c19d4e6ee57}{allPropertiesAssigned(String text)} 
\end{DoxySeeAlso}


Definition at line 101 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_ae9edf6ace6b278411d470ebd05541189}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!set@{set}}
\index{set@{set}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{set}]{\setlength{\rightskip}{0pt plus 5cm}void com.dstu.autofit.Template.set (
\begin{DoxyParamCaption}
\item[{String}]{name, }
\item[{Object}]{value}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_ae9edf6ace6b278411d470ebd05541189}


Set the property name to value. 


\begin{DoxyParams}{Parameters}
{\em name,value} & \\
\hline
\end{DoxyParams}


Definition at line 58 of file Template.java.

\hypertarget{classcom_1_1dstu_1_1autofit_1_1_template_acc464721bfb13b4f0d635a3decce96f4}{
\index{com::dstu::autofit::Template@{com::dstu::autofit::Template}!setText@{setText}}
\index{setText@{setText}!com::dstu::autofit::Template@{com::dstu::autofit::Template}}
\subsubsection[{setText}]{\setlength{\rightskip}{0pt plus 5cm}void com.dstu.autofit.Template.setText (
\begin{DoxyParamCaption}
\item[{String}]{text}
\end{DoxyParamCaption}
)}}
\label{classcom_1_1dstu_1_1autofit_1_1_template_acc464721bfb13b4f0d635a3decce96f4}


Set the target text. 



Definition at line 48 of file Template.java.



The documentation for this class was generated from the following file:\begin{DoxyCompactItemize}
\item 
C:/workspace/AutoFit/src/com/dstu/autofit/\hyperlink{_template_8java}{Template.java}\end{DoxyCompactItemize}
